package com.zzl.bonds.ticket.constant.type;

/**
 * 操作按钮 枚举值
 *
 * @author : spp
 * @date : 2022/2/22 20:37
 */
public enum OperateButtonEnum {

    /**
     * 详情
     */
    DETAILS(1, "详情"),

    CANCEL(2, "撤销"),

    REAPPLY(13, "重新申请"),
    ///////////////////////////todo 以下未核对

    CHECK(3, "复核"),

    SIGN(4, "签收"),

    TICKET_TRANSFER(5, "凭证转让"),

    TICKET_FINANCE(6, "凭证融资"),

    CANCEL_APPLY(7, "撤销申请"),
    /**
     * 融资协议签署
     */
    SIGN_FINANCE(8, "签署"),
    /**
     * 融资审批
     */
    APPROVE_FINANCE(9, "审核"),

    FRAOZEN(10, "冻结"),

    NOT_FRAOZEN(11, "解冻"),

    MODIFY(12, "修改"),


    /**
     * 融资额度
     */
    FINANCE_CREDIT_UPDATE_BUTTON(12, "修改"),
    FINANCE_CREDIT_DETAIL_BUTTON(13, "详情"),
    ;
    private final Integer code;
    private final String value;


    OperateButtonEnum(Integer code, String value) {
        this.code = code;
        this.value = value;
    }

    public static String getValue(Integer code) {
        for (OperateButtonEnum statusEnum : OperateButtonEnum.values()) {
            if (statusEnum.code.equals(code)) {
                return statusEnum.value;
            }
        }
        return "";
    }


    public Integer getCode() {
        return code;
    }

    public String getValue() {
        return value;
    }

}
